package com.winspread.ui.squareview

import android.content.Context
import android.util.AttributeSet
import androidx.annotation.Nullable
import androidx.appcompat.widget.AppCompatRadioButton
import com.winspread.ui.squareview.base.SquareView

/**
 *Author: Amin
 *Data: 2022/4/11 10:21
 *
 *Description:
 *
 */
class SquareRadioButton(
    @Nullable context: Context?,
    @Nullable attrs: AttributeSet?,
    defStyleAttr: Int,
) : AppCompatRadioButton(context, attrs, defStyleAttr) {

    init {
        SquareView(context, attrs, defStyleAttr, this)
        buttonDrawable = null
    }


    constructor(context: Context?, attrs: AttributeSet?) : this(
        context,
        attrs,
        android.R.attr.radioButtonStyle

    )

    constructor(context: Context?) : this(context, null) {

    }


//    override fun setOnClickListener(l: OnClickListener?) {
//        val onClickListener = OnClickListener {
//            l?.onClick(it)
//        }
//        super.setOnClickListener(onClickListener)
//    }
}